<?php include 'ajax.php'; ?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>OOXX</title>
<link type="text/css" rel="stylesheet" href="style.css">

</head>
<body>
<?php
function echoblock($id,$class='')
{
	echo "<div id=$id class='block $class'>$id</div>";
}

?>

<div class="content">
	<?php
	$all = ooxx::getall();
	foreach($all as $key=>$a)
	{
		if(($key-1)%10 == 0)
		{
			echo "<div class='border'>";
		}
		if($a == 1)
		{
			$class = 'p1';
		}
		else if($a ==2)
		{
			$class = 'p2';
		}
		else
		{
			$class = '';
		}
		echo "<div id='$key' class='block $class' >$key</div>";
		if(($key+1)%10 ==0)
		{
			echo "</div>";
		}
	}

	?>
<div class="clear"></div>
</div>
<p id="who" style="color:#fff">1</p>
<script src="js/j.js" type="text/javascript"></script>

<script src="js/main.js" type="text/javascript"></script>

</body>
</html>